<?php
use yii\helpers\Html;
use backend\utils\XHtml;
use yii\helpers\Url;

/* @var $this yii\web\View */

$this->title = '自定义图片上传';
$this->params['breadcrumbs'][] = ['label' => '资源管理', 'url' => ['index']];
$this->params['breadcrumbs'][] = ['label' => '图片管理', 'url' => ['images-index']];
$this->params['breadcrumbs'][] = ['label' => '自定义图片', 'url' => ['images']];
$this->params['breadcrumbs'][] = $this->title;
?>
<div class="box box-primary">
    <div class="box-body clearfix">

        <?= \kartik\file\FileInput::widget([
            'name' => 'files',
            'options' => ['accept' => 'image/*', 'multiple' => true],
            'pluginOptions' => [
                'previewFileType' => 'image',
                'initialPreviewAsData' => true,
                'uploadUrl' => Url::to(['upload-images', 'type' => 'web']),
                'uploadAsync' => true,
                'browseOnZoneClick' => true,
                'showRemove' => false,
                'fileActionSettings' => [
                    'showUpload' => false,
                ],
            ]
        ]) ?>

        <h3 class="text-center">
            <?= XHtml::backButton() ?>
        </h3>

    </div>
</div>